<template>
    <div>
        <h1>Dashboard page</h1>
        <svg-icon icon-class="bug"></svg-icon>
        <!----icon-class svg 图标名称 class-name 额外的自定义类名 @click绑定-->
        <svg-icon icon-class="404" class-name="custom-class" @click="sayHi"></svg-icon>
    </div>
</template>
<script setup lang="ts">
import { getCurrentInstance } from "vue"

const { proxy} = getCurrentInstance()!
const sayHi=()=>{
    alert('say hello')
    proxy?.$message.success('这是一条成功的信息')
}
</script>
<style lang="scss">
.custom-class{
    font-size:200px;
    color:green;
}
</style>